﻿

/*
 * THIS CLASS AND FORM ARE FOR TESTING ONLY, NOT TO BE IMPLEMENTED IN THE FINAL SOLUTION
*/


using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.IO;
using System.Reflection;



namespace quizzer_linq_3
{
    public partial class Form1 : Form
    {
        Quizzer_Data_Access gp = new Quizzer_Data_Access();
        StringBuilder sb = new StringBuilder();

        public Form1()
        {
            InitializeComponent();
            testButton_Click(new object(), new EventArgs());
            button4_Click(new object(), new EventArgs());
        }


        private void testButton_Click(object sender, EventArgs e)
        {
            var y = gp.GetAllProfessor();
            multiLineBox.Text = y;
        }

        private void button4_Click(object sender, EventArgs e)
        {
            QuestionCreatorForm a = new QuestionCreatorForm(1);
            a.ShowDialog();
        }





/*     
        private void button4_Click(object sender, EventArgs e)
        {
            try
            {
                StringWriter sw = new StringWriter(sb);
                var x = gp.GetProfessor(testBox1.Text, testBox2.Text);
                StringDumper.Write(x, 1, sw);
                textBox1.Text = (sb.ToString());
            }
            catch (Exception ex)
            {
                System.Diagnostics.Debug.WriteLine(ex.Message + ex.StackTrace);
            }
        }      
 */ 


        /*
        private void testButton_Click(object sender, EventArgs e)
        {
            var y = gp.GetProfessor(testBox1.Text, testBox2.Text);
            textBox1.Text = y;
        }
        */
    }
}
